{extend name="common/base"}
{block name="title"}我的收货地址{/block}

<body>

{block name="content"}
	<!-- 地址管理 -->
	
	<div class="segments-page">
		<div class="container">
			<div class="product-details">
				<div class="pages-title">
					<h4>我的收货地址</h4>
				</div>
                <a href="{:Url('index/cart/addAd')}{if(isset($guigetype_id))}?guigetype_id={$guigetype_id}{/if}" style="float:right;"><button class="button" type="submit"><i class="fa fa-send"></i>添加新地址</button></a><br>
				{volist name="list" id="vo"}
				<form action="{if(isset($guigetype_id))}{:url('index/cart/checkout')}?guigetype_id={$guigetype_id}{else /}{:url('index/cart/checkoutCar')}{/if}" method="post" id="subformNo{$vo.id}">
					<a href=""  onclick="document.getElementById('subformNo{$vo.id}').submit();return false">
						<div class="contents" style="margin-top:30px;width:85%;float: left;">
							<div class="desc-short">
								<p><span>{$vo.shouhuo_name}</span><span style="margin-left:15px;">{$vo.shouhuo_tell}</span></p>
								<p style="width:85%">
									{if($vo.id==$vo.address_id)}
									<span style="color:red;border:1px red solid;margin-right:5px;">默认</span>
									{/if}{$vo.shouhuo_address}
								</p>			
								<input type="hidden" value="{$vo.id}" id="address_id" name="address_id">		
							</div>
						</div>
					</a>
				</form>
				<a href="{:Url('cart/edit')}?id={$vo.id}&guigetype_id={$guigetype_id}" style="float:right;margin-top:58px;"><button class="button" type="button">编辑</button></a>
                {/volist}

			</div>
		</div>
	</div>
	
	<!-- 地址管理结束 -->
{/block}